#ifndef POSITIONMIXERMANAGER_H
#define POSITIONMIXERMANAGER_H

#include "frames.hpp"
using namespace KDL;

class PositionMixerManager
{
public:
    PositionMixerManager(double deltaTimeIn);


public:
    int reset();
    int addCeaseMotion(Frame startFrameIn, Frame endFrameIn, double startLineVelocity);
    int addStartMotion(Frame startFrameIn, Frame endFrameIn, double endLineVelocity);

    int moveOneStep_FrameCommand(Frame &frameOut, double &durationLeftOut);


private:
    Frame startFrame;
    Frame endFrame;
    double acc;
    double currentTransitionTimeAccumued;
    double timeDuration;
    double sumDistance;
    double deltaTime;
    double ratioX,ratioY,ratioZ;
    bool isCeaseMotionFlag;
    bool isTrajFinished;

};

#endif // POSITIONMIXERMANAGER_H
